home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.3 (Developer)…68k, x86, SPARC, PA-RISC] / NeXTSTEP 3.3 Dev Intel.iso / NextDeveloper / Source / GNU / libg++ / libio / stdio / getw.c < prev    next >
C/C++ Source or Header  |  1994-02-15  |  222b  |  14 lines

  1. #include "libioP.h"
  2. #include "stdio.h"
  3.  
  4. int
  5. getw(fp)
  6.      FILE *fp;
  7. {
  8.   int w;
  9.   _IO_size_t bytes_read;
  10.   COERCE_FILE(fp);
  11.   bytes_read = _IO_sgetn (fp, (char*)&w, sizeof(w));
  12.   return sizeof(w) == bytes_read ? w : EOF;
  13. }
  14.